﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;


namespace ks
{
    public partial class 登录 : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            UnobtrusiveValidationMode = UnobtrusiveValidationMode.None;
        }

        protected void Button2_Click(object sender, EventArgs e)
        {
            Label4.Text = " ";
            if (name.Text == "admin" && password.Text == "123")
            {

                Response.Write("<script>window.location.href='/后台管理.aspx'</script>");
            }
            else if (name.Text == "hkm" && password.Text == "1234")
            {
                Session["name"] = 0;
                Response.Write("<script>window.location.href='/首页.aspx'</script>");
            }
            else
            {
                Label4.Text = "账号或密码不正确！";
            }
        }

        protected void name_TextChanged(object sender, EventArgs e)
        {

        }
    }
}